package com.wangzhy;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.boot.web.servlet.ServletComponentScan;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
import springfox.documentation.swagger2.annotations.EnableSwagger2;

/**
 * @author wang2
 */
@EnableSwagger2
@MapperScan("com.wangzhy")
@ServletComponentScan
@EnableConfigurationProperties
@SpringBootApplication(scanBasePackages = { "com.wangzhy" })
public class SpiderApplication extends SpringBootServletInitializer {

    public static void main(String[] args) {
        SpringApplication.run(SpiderApplication.class, args);
    }
    @Override
    protected SpringApplicationBuilder configure(SpringApplicationBuilder application) {
        return application.sources(SpiderApplication.class);
    }
}
